"use client";
import React from "react";
import {Button} from "@mantine/core";
import {IconActivity} from "@tabler/icons-react";
import {useIpdTableContext} from "./context";

export const ButtonCompare = () => {
  // 从context中获取相关变量
  const {selectedRecords} = useIpdTableContext();
  return (
    <Button
      size="xs"
      leftSection={<IconActivity size={12} />}
      disabled={selectedRecords.length < 2}
    >
      对比
    </Button>
  );
};
